package com.ics.sapecit.service.impl;

import java.util.ArrayList;
import java.util.List;

import com.ics.sapecit.bean.User;
import com.ics.sapecit.dao.IUserDao;
import com.ics.sapecit.service.IUserService;

public class UserServiceImpl implements IUserService {
	private IUserDao userDao;
	private List<User> userList = new ArrayList<User>();
	
	
	public UserServiceImpl() {
		userList.add(new User("username1","password1"));
		userList.add(new User("username2","password2"));
	}

	public void add(User user) {
		// TODO Auto-generated method stub
		userDao.add(user);
	}

	public IUserDao getUserDao() {
		return userDao;
	}

	public void setUserDao(IUserDao userDao) {
		this.userDao = userDao;
	}

	public List<User> getUserList() {
		return userList;
	}

	public void setUserList(List<User> userList) {
		this.userList = userList;
	}

	public List<User> findUsers() {
		// TODO Auto-generated method stub
		return userDao.findUsers();
	}
	
}
